<template>
    <div class="search">
        <input @keyup.enter="search" type="search" placeholder="请输入英雄" v-model="str">
    </div>
</template>

<script>
    export default {
        name: "HeroSearch",
        data(){
            return{
                str:""
            }
        },
        methods:{
            search(){
                this.$emit("suosou",this.str)
            }
        }
    }
</script>

<style lang="scss" scoped>

</style>